<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<script src="../../resources/js-test.js"></script>
<script type="text/javascript">
description('Test that keyboard events should have a sourceCapabilities and its firesTouchEvents should be false.');

function keyHandler() {
    debug(event.type);
    shouldBeNonNull("event.sourceCapabilities");
    shouldBeFalse("event.sourceCapabilities.firesTouchEvents");
}

if (window.eventSender) {
    for (var evt of ['keydown', 'keypress', 'keyup']) {
        document.addEventListener(evt, keyHandler);
    }
    
    eventSender.keyDown(' ');
        
} else {
   debug('This test requires eventSender.');
}

</script>